import { App } from 'vue'
import SAside from '../package/aside/index.ts'
import SHeader from '../package/header/index.ts'
import SContainer from '../package/container/index.ts'
import SFooter from '../package/footer/index.ts'
import SForm from '../package/form/index.ts'
import SFormItem from '../package/form-item/index.ts'
import SInput from '../package/input/index.ts'
import SButton from '../package/button/index.ts'
import SDialog from '../package/dialog/index.ts'
import STree from '../package/tree/index.ts'
const components = [
  SAside,
  SHeader,
  SContainer,
  SFooter,
  SForm,
  SFormItem,
  SInput,
  SButton,
  SDialog,
  STree,
]

const install = (app: App) => {
  components.forEach((component) => {
    app.component(component.name, component)
  })
}

export default {
  install,
  SAside,
  SHeader,
  SContainer,
  SFooter,
  SForm,
  SFormItem,
  SInput,
  SButton,
  SDialog,
  STree,
}
